package com.mao.controller;

import com.mao.NotFoundException;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

/**
 * Created by kechelle on 2020/8/4 10:36
 */
@Controller
public class IndexController {

    @GetMapping("/")
    public String index(){
        //int i = 9/0;
        /*
        String blog = null;
        if (blog == null){
            throw new NotFoundException();
        }*/
        return "index";
    }

    @GetMapping("/blog")
    public String blog(){
        return "blog";
    }

}
